<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        var weather = prompt('今天下雨了吗？');
        if(weather == '下雨'){
            alert('记得带伞呦！');
        }

        var age = prompt('请输入年龄：');
        if(age >= 18){
            alert('已成年');
        }else{
            alert('未成年');
        }

        var grade = prompt('请输入你的分数：');
        if(grade >= 90){
            document.write('<h2>优秀</h2>');
        }else  if(grade >= 80){
            document.write('<h2>良好</h2>');
        }else  if(grade >= 70){
            document.write('<h2>中等</h2>');
        }else  if(grade >= 60){
            document.write('<h2>及格</h2>');
        }else{
            document.write('<h2>不及格</h2>');
        }

        
    </script>
</body>
</html>